<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class Shop extends Model
{
    use HasFactory;

    use HasFactory;
    use SoftDeletes;
    /**商品分类表
     * yangrui
     * @var string
     */
    protected $table='new_shop';
    protected $guarded=[];
    protected $fillable=[
        'goods_name','goods_price','market_price','cost_price','goods_number','goods_remark',
        'goods_desc','goods_logo','brand_id','mould_id','weight','volume','keywords','is_on_sale',
        'is_free_shipping','is_recommend','is_new','is_hot','sort','suppliers_id','goods_attr',
    ];

    /**
     * Name:多条件搜索列表展示
     * User: yangrui
     * Date: 2023/6/17
     * Time:8:25
     * @param $num
     * @return mixed
     */
    public static function list($num){
        $data=Shop::paginate($num);
        return $data;
    }

}

